IXI Visual Tcl applications are intended to run equally well in character mode or in the graphical environment. However, the screen size available to an application varies with the type of display, and some programs may be forced to use different visual interfaces.
Note that all option names, as described in Generic IXI Visual Tcl Options in vtcl(TCL), can be prefixed with either CHARM_ or MOTIF_. If an option begins with CHARM_ it will only be sent to the character mode server. If it is prefixed by MOTIF_ it will only go to the Motif-based (graphical) server. These prefixes are typically used when specifying offsets, since the graphical server needs pixels and the character mode server needs characters as measurements. If neither prefix is used, then the option and its value are sent to both servers.
For example, the following small application displays a different label depending on whether it is executed in character or graphical
set app [VtOpen myprog] set form [VtFormDialog $app.mainform -ok -okLabel Goodbye \ -okCallback VtClose] set label [VtLabel $form.label \ -CHARM_label "Running in character mode" \ -MOTIF_label "Running under Motif"] VtShow $form VtMainLoop